Skip to content

Conversation

@bastikohn
Copy link

Summary

  • Extend smoothDamp with an optional shortestAngle wrap mode so theta easing can interpolate across ±π without swinging the long way.
  • Add a smoothRotationTheta property (default true) that opts azimuth damping into the shortest-path behavior while leaving an escape hatch for legacy workflows.
  • Document the new option and call out how it pairs with normalizeAzimuthAngle() for predictable wrap handling.

Context

Previously, any smoothed azimuth transition that crossed the ±180° boundary could trigger a ~360° spin; this was especially noticeable when snapping between near-opposite headings. With the new wrap logic we always take the minimal rotational delta, yielding the expected short 2–3° ease.

@bastikohn bastikohn changed the title feat: wrap around transitions between azimuth angles close to ±180° fix: wrap around transitions between azimuth angles close to ±180° Nov 2, 2025
@bastikohn bastikohn force-pushed the fix/wrap_theta_rotations branch from c86c8f2 to f5f46f3 Compare November 2, 2025 22:32
@bastikohn bastikohn force-pushed the fix/wrap_theta_rotations branch from f5f46f3 to c09219b Compare November 2, 2025 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant